//
//  ViewController.m
//  28作业拉钩动画
//
//  Created by dllo on 16/8/22.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "ViewController.h"
#import "Masonry.h"
#import "UIView+Frame.h"
@interface ViewController ()

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *LoginCenterY;

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *wangjimimaCenterX;


@property (weak, nonatomic) IBOutlet UIButton *wangjiButton;
@property (weak, nonatomic) IBOutlet UIImageView *renImageView;


@property (weak, nonatomic) IBOutlet UIImageView *shangrenImageView;

@property (weak, nonatomic) IBOutlet UIButton *dengluButton;

@property (weak, nonatomic) IBOutlet UITextField *topUITextField;

@property (weak, nonatomic) IBOutlet UITextField *bottomTextField;
@property (weak, nonatomic) IBOutlet UILabel *rightLabel;

@property (weak, nonatomic) IBOutlet UILabel *leftLabel;

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *topTextFieldWidth;

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *topTextFieldright;

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *leftLabeldistance;
@property (weak, nonatomic) IBOutlet NSLayoutConstraint *leftLabelWidth;
@property (weak, nonatomic) IBOutlet NSLayoutConstraint *dengluWidth;

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *rightTextFieldWidth;

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *rightLabelWidth;

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *topImageViewWidth;

@property (weak, nonatomic) IBOutlet NSLayoutConstraint *bottomImageWidth;


@end

@implementation ViewController




- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
    _wangjiButton.transform = CGAffineTransformMakeTranslation(100, 0);
    
}




- (void)viewDidAppear:(BOOL)animated
{
    [super viewDidAppear:animated];


    _LoginCenterY.constant = -160;

    
    _topTextFieldWidth.constant = 315;
    _rightTextFieldWidth.constant = 315;
    
    
    
    _topImageViewWidth.constant = 40;
    _bottomImageWidth.constant = 40;
    
    
    
    _leftLabelWidth.constant = 200;
    _rightLabelWidth.constant = 200;
    _dengluWidth.constant = 355;
    [UIView animateWithDuration:1 animations:^{
        [self.view layoutIfNeeded];
        _wangjiButton.transform = CGAffineTransformIdentity;
    }];
    

    
    
    
}






- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}


@end
